package com.spaceobj.project.controller;

import cn.dev33.satoken.util.SaResult;
import com.spaceobj.common.core.utils.SourceToTargetUtils;
import com.spaceobj.project.bo.GetPhoneNumberBo;
import com.spaceobj.project.bo.ProjectSearchBo;
import com.spaceobj.project.dto.GetPhoneNumberDto;
import com.spaceobj.project.dto.ProjectSearchDto;
import com.spaceobj.project.dto.SysProjectDto;
import com.spaceobj.project.group.*;
import com.spaceobj.project.pojo.SysProject;
import com.spaceobj.project.pojo.SysSearchContent;
import com.spaceobj.project.service.SysProjectService;
import com.spaceobj.project.service.SysSearchContentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;

/**
 * @author zhr_java@163.com
 * @date 2022/9/5 22:11
 */
@RestController(value = "searchContentController")
@RequestMapping(value = "searchContent", method = RequestMethod.POST)
public class SysSearchContentController {

  @Autowired private SysSearchContentService sysSearchContentService;

  @PostMapping(value = "add")
  public SaResult add(SysSearchContent sysSearchContent) {
    return sysSearchContentService.add(sysSearchContent);
  }

  @PostMapping(value = "update")
  public SaResult update(SysSearchContent sysSearchContent) {
    return sysSearchContentService.update(sysSearchContent);
  }

  @PostMapping("list")
  public SaResult list(SysSearchContent sysSearchContent) {
    return sysSearchContentService.list(sysSearchContent);
  }

  @PostMapping(value = "findById")
  public SaResult findById(long id) {

    return sysSearchContentService.findById(id);
  }

}
